Last updated: 2021-11-25

Checks: 6 1

Knit directory: mapme.protectedareas/

This reproducible R Markdown analysis was created with workflowr (version 1.6.2). The Checks tab describes the reproducibility checks that were applied when the results were created. The Past versions tab lists the development history.


The R Markdown is untracked by Git. To know which version of the R Markdown file created these results, you’ll want to first commit it to the Git repo. If you’re still working on the analysis, you can ignore this warning. When you’re finished, you can run wflow_publish to commit the R Markdown file and build the HTML.

Great job! The global environment was empty. Objects defined in the global environment can affect the analysis in your R Markdown file in unknown ways. For reproduciblity it’s best to always run the code in an empty environment.

The command set.seed(20210305) was run prior to running the code in the R Markdown file. Setting a seed ensures that any results that rely on randomness, e.g. subsampling or permutations, are reproducible.

Great job! Recording the operating system, R version, and package versions is critical for reproducibility.

Nice! There were no cached chunks for this analysis, so you can be confident that you successfully produced the results during this run.

Great job! Using relative paths to the files within your workflowr project makes it easier to run your code on other machines.

Great! You are using Git for version control. Tracking code development and connecting the code version to the results is critical for reproducibility.

The results in this page were generated with repository version e151d99. See the Past versions tab to see a history of the changes made to the R Markdown and HTML files.

Note that you need to be careful to ensure that all relevant files for the analysis have been committed to Git prior to generating the results (you can use wflow_publish or wflow_git_commit). workflowr only checks the R Markdown file, but you know if there are other scripts or data files that it depends on. Below is the status of the Git repository when the results were generated:


Ignored files:
    Ignored:    .Rproj.user/

Untracked files:
    Untracked:  analysis/descriptives.Rmd

Unstaged changes:
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/bootstrap-theme.css
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/bootstrap-theme.css.map
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/bootstrap-theme.min.css
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/bootstrap.css
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/bootstrap.css.map
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/bootstrap.min.css
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/cerulean.min.css
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/cosmo.min.css
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/darkly.min.css
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/flatly.min.css
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/fonts/Lato.ttf
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/fonts/LatoBold.ttf
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/fonts/LatoItalic.ttf
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/fonts/NewsCycle.ttf
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/fonts/NewsCycleBold.ttf
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/fonts/OpenSans.ttf
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/fonts/OpenSansBold.ttf
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/fonts/OpenSansBoldItalic.ttf
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/fonts/OpenSansItalic.ttf
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/fonts/OpenSansLight.ttf
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/fonts/OpenSansLightItalic.ttf
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/fonts/Raleway.ttf
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/fonts/RalewayBold.ttf
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/fonts/Roboto.ttf
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/fonts/RobotoBold.ttf
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/fonts/RobotoLight.ttf
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/fonts/RobotoMedium.ttf
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/fonts/SourceSansPro.ttf
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/fonts/SourceSansProBold.ttf
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/fonts/SourceSansProItalic.ttf
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/fonts/SourceSansProLight.ttf
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/fonts/Ubuntu.ttf
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/journal.min.css
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/lumen.min.css
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/paper.min.css
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/readable.min.css
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/sandstone.min.css
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/simplex.min.css
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/spacelab.min.css
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/united.min.css
    Deleted:    analysis/site_libs/bootstrap-3.3.5/css/yeti.min.css
    Deleted:    analysis/site_libs/bootstrap-3.3.5/fonts/glyphicons-halflings-regular.eot
    Deleted:    analysis/site_libs/bootstrap-3.3.5/fonts/glyphicons-halflings-regular.svg
    Deleted:    analysis/site_libs/bootstrap-3.3.5/fonts/glyphicons-halflings-regular.ttf
    Deleted:    analysis/site_libs/bootstrap-3.3.5/fonts/glyphicons-halflings-regular.woff
    Deleted:    analysis/site_libs/bootstrap-3.3.5/fonts/glyphicons-halflings-regular.woff2
    Deleted:    analysis/site_libs/bootstrap-3.3.5/js/bootstrap.js
    Deleted:    analysis/site_libs/bootstrap-3.3.5/js/bootstrap.min.js
    Deleted:    analysis/site_libs/bootstrap-3.3.5/js/npm.js
    Deleted:    analysis/site_libs/bootstrap-3.3.5/shim/html5shiv.min.js
    Deleted:    analysis/site_libs/bootstrap-3.3.5/shim/respond.min.js
    Deleted:    analysis/site_libs/font-awesome-5.1.0/css/all.css
    Deleted:    analysis/site_libs/font-awesome-5.1.0/css/v4-shims.css
    Deleted:    analysis/site_libs/font-awesome-5.1.0/webfonts/fa-brands-400.eot
    Deleted:    analysis/site_libs/font-awesome-5.1.0/webfonts/fa-brands-400.svg
    Deleted:    analysis/site_libs/font-awesome-5.1.0/webfonts/fa-brands-400.ttf
    Deleted:    analysis/site_libs/font-awesome-5.1.0/webfonts/fa-brands-400.woff
    Deleted:    analysis/site_libs/font-awesome-5.1.0/webfonts/fa-brands-400.woff2
    Deleted:    analysis/site_libs/font-awesome-5.1.0/webfonts/fa-regular-400.eot
    Deleted:    analysis/site_libs/font-awesome-5.1.0/webfonts/fa-regular-400.svg
    Deleted:    analysis/site_libs/font-awesome-5.1.0/webfonts/fa-regular-400.ttf
    Deleted:    analysis/site_libs/font-awesome-5.1.0/webfonts/fa-regular-400.woff
    Deleted:    analysis/site_libs/font-awesome-5.1.0/webfonts/fa-regular-400.woff2
    Deleted:    analysis/site_libs/font-awesome-5.1.0/webfonts/fa-solid-900.eot
    Deleted:    analysis/site_libs/font-awesome-5.1.0/webfonts/fa-solid-900.svg
    Deleted:    analysis/site_libs/font-awesome-5.1.0/webfonts/fa-solid-900.ttf
    Deleted:    analysis/site_libs/font-awesome-5.1.0/webfonts/fa-solid-900.woff
    Deleted:    analysis/site_libs/font-awesome-5.1.0/webfonts/fa-solid-900.woff2
    Deleted:    analysis/site_libs/highlightjs-9.12.0/default.css
    Deleted:    analysis/site_libs/highlightjs-9.12.0/highlight.js
    Deleted:    analysis/site_libs/highlightjs-9.12.0/textmate.css
    Deleted:    analysis/site_libs/jquery-3.6.0/jquery-3.6.0.js
    Deleted:    analysis/site_libs/jquery-3.6.0/jquery-3.6.0.min.js
    Deleted:    analysis/site_libs/jquery-3.6.0/jquery-3.6.0.min.map
    Deleted:    analysis/site_libs/navigation-1.1/codefolding.js
    Deleted:    analysis/site_libs/navigation-1.1/sourceembed.js
    Deleted:    analysis/site_libs/navigation-1.1/tabsets.js

Note that any generated files, e.g. HTML, png, CSS, etc., are not included in this status report because it is ok for generated content to have uncommitted changes.


There are no past versions. Publish this analysis with wflow_publish() to start tracking its development.


Introduction

Relative forest cover – exploratory

All observations

Outliers excluded

wdpa_pid NAME ISO3 AREA_KM2
31758 Área De Proteção Ambiental Serra Da Tabatinga BRA 417.9696
30628 Río Indio Maíz NIC 3161.2738

From this point onwards, all plots exclude aforementioned outliers.

Grouped by countries

Grouped by accessibililty

Grouped by accessibility, country

Relative forest cover: Fitted lines

Slope coefficients


(Slope) coefficients with break at relative year == 1
========================================================
                                 Dependent variable:    
                             ---------------------------
                                 area_pct_projstart     
--------------------------------------------------------
Dummy before vs. after start          -0.004***         
                                       (0.001)          
                                                        
Relative year                         -0.001***         
                                      (0.0001)          
                                                        
Relative year X Dummy                  0.0001           
                                      (0.0001)          
                                                        
Constant                              1.000***          
                                       (0.001)          
                                                        
--------------------------------------------------------
Observations                            9,009           
R2                                      0.188           
Adjusted R2                             0.187           
Residual Std. Error               0.023 (df = 9005)     
F Statistic                   693.886*** (df = 3; 9005) 
========================================================
Note:                        *p<0.1; **p<0.05; ***p<0.01

Fitted lines and scattered points

Fitted lines and CIs only

Grouped by accessibility bins

Alternative accessibility bins


       (0,120]      (120,240]      (240,300] (300,4.91e+03] 
          4053           1848            525           2289 

Relative forest cover: Boxplots


R version 3.6.3 (2020-02-29)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 18.04.6 LTS

Matrix products: default
BLAS:   /usr/lib/x86_64-linux-gnu/blas/libblas.so.3.7.1
LAPACK: /usr/lib/x86_64-linux-gnu/lapack/liblapack.so.3.7.1

locale:
 [1] LC_CTYPE=C.UTF-8       LC_NUMERIC=C           LC_TIME=C.UTF-8       
 [4] LC_COLLATE=C.UTF-8     LC_MONETARY=C.UTF-8    LC_MESSAGES=C.UTF-8   
 [7] LC_PAPER=C.UTF-8       LC_NAME=C              LC_ADDRESS=C          
[10] LC_TELEPHONE=C         LC_MEASUREMENT=C.UTF-8 LC_IDENTIFICATION=C   

attached base packages:
[1] grid      stats     graphics  grDevices utils     datasets  methods  
[8] base     

other attached packages:
 [1] ggpmisc_0.4.4   ggpp_0.4.2      stargazer_5.2.2 forcats_0.5.1  
 [5] stringr_1.4.0   dplyr_1.0.7     purrr_0.3.4     readr_1.4.0    
 [9] tidyr_1.1.4     tibble_3.1.5    tidyverse_1.3.1 plotly_4.9.3   
[13] ggplot2_3.3.4   sf_1.0-3       

loaded via a namespace (and not attached):
 [1] nlme_3.1-152       matrixStats_0.57.0 fs_1.5.0           lubridate_1.7.10  
 [5] httr_1.4.2         rprojroot_2.0.2    tools_3.6.3        backports_1.2.1   
 [9] bslib_0.2.5.1      utf8_1.2.2         R6_2.5.1           KernSmooth_2.23-20
[13] mgcv_1.8-36        DBI_1.1.1          lazyeval_0.2.2     colorspace_2.0-1  
[17] withr_2.4.2        tidyselect_1.1.1   compiler_3.6.3     git2r_0.28.0      
[21] cli_3.0.1          rvest_1.0.0        quantreg_5.86      SparseM_1.78      
[25] xml2_1.3.2         labeling_0.4.2     sass_0.4.0         scales_1.1.1      
[29] classInt_0.4-3     proxy_0.4-26       digest_0.6.27      rmarkdown_2.11    
[33] pkgconfig_2.0.3    htmltools_0.5.1.1  highr_0.8          dbplyr_2.1.1      
[37] htmlwidgets_1.5.3  rlang_0.4.12       readxl_1.3.1       rstudioapi_0.13   
[41] jquerylib_0.1.4    generics_0.1.0     farver_2.1.0       jsonlite_1.7.2    
[45] crosstalk_1.1.1    magrittr_2.0.1     polynom_1.4-0      Matrix_1.3-4      
[49] Rcpp_1.0.7         munsell_0.5.0      fansi_0.5.0        lifecycle_1.0.1   
[53] stringi_1.6.2      yaml_2.2.1         promises_1.2.0.1   crayon_1.4.1      
[57] lattice_0.20-44    splines_3.6.3      haven_2.3.1        hms_1.1.1         
[61] knitr_1.34         pillar_1.6.4       reprex_2.0.0       glue_1.4.2        
[65] evaluate_0.14      data.table_1.13.6  modelr_0.1.8       vctrs_0.3.8       
[69] httpuv_1.6.1       MatrixModels_0.4-1 cellranger_1.1.0   gtable_0.3.0      
[73] assertthat_0.2.1   xfun_0.24          broom_0.7.6        e1071_1.7-9       
[77] later_1.2.0        class_7.3-19       viridisLite_0.4.0  conquer_1.0.2     
[81] workflowr_1.6.2    units_0.7-2        ellipsis_0.3.2